

package com.hazelcast.jet.impl.execution;

import java.io.Serial;
import java.util.AbstractMap.SimpleImmutableEntry;
import java.util.Map.Entry;

/**
 * A Map.Entry implementation which implements {@link BroadcastItem}.
 *
 * @param <K> type of key
 * @param <V> type of value
 */
public final class BroadcastEntry<K, V> extends SimpleImmutableEntry<K, V> implements BroadcastItem {

    @Serial
    private static final long serialVersionUID = 1L;

    public BroadcastEntry(K key, V value) {
        super(key, value);
    }

    public BroadcastEntry(Entry<? extends K, ? extends V> entry) {
        super(entry);
    }

    @Override
    public String toString() {
        return getKey() + "=" + getValue();
    }
}
